<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<title>Ta的动态</title>
		<link href="../css/mui.min.css" rel="stylesheet" />
		<link rel="stylesheet" type="text/css" href="../css/app.css" />
		<link rel="stylesheet" type="text/css" href="../fonts/iconfont/iconfont.css" />
		<link rel="stylesheet" type="text/css" href="../css/global.css" />
		<link rel="stylesheet" type="text/css" href="../css/pullToRefresh.css" />
	</head>

	<body ng-app="app" ng-controller="myController">
		<header class="mui-bar mui-bar-nav">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 class="mui-title colorP">Ta的动态</h1>
		</header>
		<div class="mui-content"> 
			<div class="mui-table-view-cell padding0 bg_white">
				<ul class="mui-table-view" ng-repeat="(key,res) in info">
					<li ng-repeat="(key,vo) in res" class="mui-table-view-cell mui-media">
						<a href="javascript:;" class="mui-clearfix" ng-click="comein(vo.id,vo.status,vo.from_id)">
							<img class="mui-media-object mui-pull-right" ng-src="{{vo.img}}">
							<ul class="mui-media-body mui-pull-left user_view">
								<li>
									<div class="user_pic"><img ng-src="{{icon}}" /></div>
									<span class="padding_l">{{nick}}</span>
								</li>
								<li>
									<i class="iconfont mui-icon icon-color">&#xe615;</i>
									<span class="padding_l">{{vo.comment}}</span>
								</li>
								<li>
									<i class="iconfont mui-icon icon-color">&#xe60a;</i>
									<span class="padding_l">{{vo.tags}}</span>
								</li> 
							</ul>
						</a>
					</li>
				</ul>
			</div>
		</div>
	</body>
	<script src="../js/mui.min.js"></script>
	<script src="../js/mui.pullToRefresh.js"></script>
	<script src="../js/mui.pullToRefresh.material.js"></script>
	<script src="../js/open.js"></script>
	<script src="../js/jquery.min.js"></script>
	<script src="../js/angular.min.js"></script>
	<script src="../js/apppublic.js"></script>
	<script src="../js/app/somebody_dynamic_state.js"></script>
	<script type="text/javascript">
		(function($) {
			//阻尼系数
			var deceleration = mui.os.ios ? 0.003 : 0.0009;
			$('.mui-scroll-wrapper').scroll({
				bounce: false,
				indicators: false, //是否显示滚动条
				deceleration: deceleration
			});

			$.ready(function() {
				//循环初始化所有下拉刷新，上拉加载。
				$.each(document.querySelectorAll('.mui-content'), function(index, pullRefreshEl) {
					$(pullRefreshEl).pullToRefresh({
						down: {
							callback: function() {
								var self = this;
								setTimeout(function() {
									loadNews();
									self.endPullDownToRefresh();
								}, 1000);
							}
						},
						up: {
							callback: function() {
								var self = this;
								getValue();
								setTimeout(function() {
									self.endPullUpToRefresh();
								}, 1000);
							}
						}
					});
				});
			});
		})(mui);
		
		
		function loadNews(){
			var allocation = document.querySelector('[ng-controller=myController]');
			$scope = angular.element(allocation).scope();
			page = 1;
			res=[];
			noMore = false;
			$scope.initView();
			$scope.$apply();
		}
		function getValue(){
			var allocation = document.querySelector('[ng-controller=myController]');
			$scope = angular.element(allocation).scope();
			page++;
			$scope.initView();
			$scope.$apply();
		}
	</script>

</html>